﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using JCTimes.DomainModel.Repository;
using JCTimes.DomainModel.Entity;

namespace JCTimes.EFRepository.RepositoryImpl
{
    public class UserRepository : BaseRepository<User>, IUserRepository
    {
        JCTimesDbContext db = new JCTimesDbContext();

        public IQueryable<User> GetAccount(string parentid)
        {
            return from r in db.Users
                   from p in db.Users
                   where r.ID == parentid
                   where p.ParentID == r.ID
                   select p;
        }
    }
}
